package com.hz.ruoyistorage.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hz.ruoyistorage.domain.LgColdSlot;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @version 1.0
 * @Author gj
 * @Date 2025/3/7 15:14
 * @注释
 */
public interface LgColdSlotMapper extends BaseMapper<LgColdSlot> {
    @Select("select * from lg_cold_slot where sub_id = #{subId}")
    List<LgColdSlot> getAllBySubId(Integer subId);

    @Insert("insert into lg_cold_slot(sub_id,slot_name,`row`,`column`,depth,create_by" +
            ") values" +
            "(#{subId},#{slotName},#{row},#{column},#{depth},#{createBy})")
    int addSlot(LgColdSlot lgColdSlot);
}
